feat(T2): dissolve the I-ISO region-programming core — and a 40% SRAM finding - #262
Merged
Conversation
… finding
Second isolation-core module onto the dissolve path after hm-thin. Unlike HM this one
HAS a seam, so it tests the part that matters.
THE SEAM SURVIVES EXACTLY.
plain/src/mpu_switch.rs + mpu.rs (Verus+Kani verified, lifted VERBATIM)
-> wasm 7120 B -> component 8464 B -> meld -> loom -> synth
undefined symbols: [ mpu-write ]
One atom, exactly as declared -- nothing undeclared crept in, nothing was swallowed.
Lifted verbatim: size_field, rasr_for, RegionTable (new / program_partition /
switch_to_partition / try_add_region / covers_addr), apply_program, emit_write, plus
is_power_of_two, validate_region and MIN_REGION_SIZE from mpu.rs.
THE FOOTPRINT, AND WHY MY FIRST NUMBER WAS WRONG.
Compiled the way hm-thin was, this object reports text 3614, data 0, bss 0. True and
MISLEADING: without --native-pointer-abi the linear memory is not reserved in the
object -- the embedder supplies it -- and this module declares 17 wasm pages,
1088 KB. "Zero SRAM" would have been wrong by a factor of 136 on an 8 KB part. I
nearly recorded it, because the object's own section table supports the wrong claim.
With the shadow-stack re-base the OS-node builds already use (#383):
shadow 2048 text 3744 data 636 bss 2688 SRAM 3324 B of 8192 = 40.6%
shadow 1024 bss 1664 SRAM 2300 B = 28.1%
shadow 512 bss 1152 SRAM 1788 B = 21.8%
THE CONSTRAINT THIS SURFACES: at the standard budget this ONE module takes 40.6% of
the F100's RAM. The isolation core is three modules, and a system also needs the OS
and an application. Either the budget comes down for this module or the F100 does not
host a multi-partition configuration. That belongs to the partition work, not to this
file. And the budget is ASSERTED, not proven -- the 2048-of-8192 gap already recorded.
BIN-VERIFY: 7 functions, 7 rules verified, 0 failed, 0 unknown, 20 LRAT expansions.
NOT zero-gap: 356 i32.const, skipped by BIN-VERIFY and Admitted in Rocq, so covered by
neither half -- more than ten times hm-thin's 29. synth#933 / synth#935.
NOT established: no evidence-on-wasm (no witness MC/DC, no scry, REQ-OS-ISO-001
oracles not re-run against the wasm build); nothing has executed the object; mpu_write
remains trusted native code including its barrier-pairing contract -- what moved is
the region-programming POLICY; partition_switch (3 seams) remains.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011QG86sovTbfnPNY9SfhSmo
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Second isolation-core module onto the dissolve path after
hm-thin. Unlike HM this one has a seam, so it tests the part that matters.The seam survives exactly
One atom, exactly as declared. Nothing undeclared crept in; nothing was swallowed.
The footprint — and why my first number was wrong
Compiled the way
hm-thinwas, this object reportstext 3614, data 0, bss 0.True and misleading. Without
--native-pointer-abithe linear memory isn't reserved in the object — the embedder supplies it — and this module declares 17 wasm pages (1 088 KB). "Zero SRAM" would have been wrong by a factor of 136 on an 8 KB part. I nearly recorded it, because the object's own section table supports the wrong claim.With the shadow-stack re-base the OS-node builds already use:
--shadow-stack-sizeThe constraint
At the standard budget this one module takes 40.6% of the F100's RAM. The isolation core is three modules, and a system needs the OS and an application too. Either the budget comes down for this module, or the F100 doesn't host a multi-partition configuration.
That's a finding for the partition work. And the budget is asserted, not proven — the
2048 of 8192gap already on record.BIN-VERIFY
Not zero-gap: 356
i32.const— skipped by BIN-VERIFY,Admittedin Rocq, covered by neither half. More than ten timeshm-thin's 29. synth#933 / synth#935.Not established
REQ-OS-ISO-001oracles not re-run against the wasm buildmpu_writeremains trusted native code including its barrier-pairing contract — what moved is the region-programming policypartition_switch(3 seams) remains